package o;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.SparseArray;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.view.animation.Animation;
import android.view.animation.Animation.AnimationListener;
import android.view.animation.TranslateAnimation;
import android.view.inputmethod.InputMethodManager;
import android.widget.AbsListView;
import android.widget.AbsListView.OnScrollListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemSelectedListener;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RatingBar;
import android.widget.RelativeLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import com.huawei.appgallery.appcomment.impl.bean.GetCommentResBean.AppCommentInfo;
import com.huawei.appgallery.appcomment.impl.bean.GetReplyResBean;
import com.huawei.appgallery.appcomment.impl.bean.GetReplyResBean.ReplyComment;
import com.huawei.appgallery.appcomment.ui.AppCommentReplyActivity.c;
import com.huawei.appgallery.appcomment.ui.AppReplyFragment;
import com.huawei.appgallery.appcomment.ui.adapter.AppReplyListAdapter;
import com.huawei.appgallery.appcomment.ui.view.CommentItemView;
import com.huawei.appgallery.appcomment.ui.view.PublishReplyView;
import com.huawei.appgallery.appcomment.ui.view.ReplyEditText;
import com.huawei.appgallery.appcomment.widget.SpinnerAdapter;
import com.huawei.appgallery.foundation.service.common.protocol.AppDetailActivityProtocol;
import com.huawei.appgallery.foundation.service.common.protocol.AppDetailActivityProtocol.Request;
import com.huawei.appgallery.foundation.ui.framework.cardframe.fragment.TaskFragment;
import com.huawei.appgallery.foundation.ui.framework.widget.PullUpListView;
import com.huawei.appgallery.foundation.ui.framework.widget.PullUpListView.a;
import com.huawei.appgallery.jsonkit.api.JsonBean;
import com.huawei.appgallery.serverreqkit.api.bean.ResponseBean;
import huawei.widget.HwSpinner;
import huawei.widget.HwTextView;
import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
import o.bcg.d;
import o.bcg.e;
import o.bcg.f;
import o.bcg.h;

public class bea implements OnClickListener, OnScrollListener, com.huawei.appgallery.appcomment.ui.view.PublishReplyView.b, com.huawei.appgallery.appcomment.ui.AppCommentReplyActivity.b, c {
    private static final String ˎ = bea.class.getSimpleName();
    private long ʻ;
    private boolean ʻॱ = true;
    private String ʼ;
    private boolean ʼॱ = true;
    private ReplyEditText ʽ;
    private View ʽॱ;
    private View ʾ;
    private TextView ʿ;
    private int ˈ = 0;
    private RelativeLayout ˉ;
    private bdl ˊ;
    private TextView ˊˊ;
    private ImageView ˊˋ;
    private String ˊॱ;
    private TextView ˊᐝ;
    private SparseArray ˋ = new SparseArray(0);
    private int ˋˊ = 0;
    private AppReplyListAdapter ˋˋ;
    private ReplyComment ˋॱ;
    private int ˋᐝ;
    private int ˌ;
    private int ˍ;
    private int ˎˎ;
    private PullUpListView ˏ = null;
    private int ˏˏ;
    private int ˏॱ = -1;
    private LinearLayout ͺ;
    private boolean ͺॱ = false;
    private int ॱ = 0;
    private String ॱˊ;
    private boolean ॱˋ = false;
    private TaskFragment ॱˎ;
    private PublishReplyView ॱॱ;
    private RelativeLayout ॱᐝ;
    private CommentItemView ᐝ;
    private View ᐝॱ;

    static class b {
        int ˊ = 0;
        int ॱ = 0;

        b() {
        }
    }

    public View ˏ(LayoutInflater layoutInflater, ViewGroup viewGroup, Bundle bundle) {
        this.ᐝॱ = layoutInflater.inflate(d.ॱˊ, null);
        this.ᐝ = new CommentItemView(this.ᐝॱ.getContext(), true);
        this.ˏ = (PullUpListView) this.ᐝॱ.findViewById(e.ʻˋ);
        this.ॱॱ = (PublishReplyView) this.ᐝॱ.findViewById(e.ʼʽ);
        this.ॱॱ.setCommentId(this.ʼ);
        this.ॱॱ.setOnReplyCommitClickListener(this);
        this.ͺ = (LinearLayout) this.ᐝ.findViewById(e.ˉॱ);
        LinearLayout linearLayout = (LinearLayout) this.ᐝ.findViewById(e.ʼˊ);
        this.ˉ = (RelativeLayout) this.ᐝॱ.findViewById(e.ˋᐝ);
        this.ˊˋ = (ImageView) this.ᐝॱ.findViewById(e.ˎˎ);
        this.ˊˊ = (TextView) this.ᐝॱ.findViewById(e.ʾˋ);
        this.ˊᐝ = (TextView) this.ᐝॱ.findViewById(e.ˌ);
        this.ˉ.setOnClickListener(new ckt(this));
        linearLayout.setPadding(0, this.ˋᐝ, 0, 0);
        ʻ();
        this.ʽ = this.ॱॱ.ˋ();
        this.ˊ = (bdl) ((AppReplyFragment) this.ॱˎ).ॱ();
        this.ˋˋ = new AppReplyListAdapter(this.ॱˎ.ॱˋ(), this.ˊ);
        this.ˋˋ.setItemViewClickListener(this);
        this.ˏ.setAdapter(this.ˋˋ);
        this.ˏ.setOnScrollListener(this);
        if (this.ॱˎ instanceof a) {
            this.ˏ.setLoadingListener((a) this.ॱˎ);
        }
        this.ˏ.addHeaderView(this.ᐝ);
        ʼ();
        this.ˏ.setVisibility(8);
        this.ͺ.setOnClickListener(new ckt(new OnClickListener(this) {
            final /* synthetic */ bea ॱ;

            {
                this.ॱ = r1;
            }

            public void onClick(View view) {
                this.ॱ.ˊ.ˏ(2);
                this.ॱ.ˋ(null, this.ॱ.ॱˊ);
                this.ॱ.ॱˊ();
            }
        }));
        return this.ᐝॱ;
    }

    private void ˋ(int i) {
        if (this.ˉ != null) {
            this.ˉ.setVisibility(i);
        }
        if (this.ʽॱ != null) {
            this.ʽॱ.setVisibility(i);
        }
        if (this.ʾ != null) {
            this.ʾ.setVisibility(i);
        }
    }

    public void ॱ(TaskFragment taskFragment) {
        this.ॱˎ = taskFragment;
    }

    private void ʼ() {
        ((ImageView) this.ᐝ.findViewById(e.ʼˋ)).setVisibility(8);
    }

    private void ʻ() {
        HwSpinner hwSpinner = (HwSpinner) this.ᐝ.findViewById(e.ʴ);
        this.ॱᐝ = (RelativeLayout) this.ᐝ.findViewById(e.ʿˊ);
        this.ʿ = (TextView) this.ᐝ.findViewById(e.ʹॱ);
        this.ʽॱ = this.ᐝॱ.findViewById(e.ʻᐝ);
        this.ʾ = this.ᐝ.findViewById(e.ʻᐝ);
        Context context = this.ᐝॱ.getContext();
        List arrayList = new ArrayList();
        arrayList.add(context.getResources().getString(h.ˊʻ));
        arrayList.add(context.getResources().getString(h.ॱʿ));
        hwSpinner.setAdapter(new SpinnerAdapter(context, arrayList));
        if (this.ˏॱ != -1) {
            hwSpinner.setSelection(this.ˏॱ - 1);
            this.ʼॱ = true;
        }
        hwSpinner.setOnItemSelectedListener(new OnItemSelectedListener(this) {
            final /* synthetic */ bea ˎ;

            {
                this.ˎ = r1;
            }

            public void onItemSelected(AdapterView<?> adapterView, View view, int i, long j) {
                if (this.ˎ.ʼॱ) {
                    this.ˎ.ʼॱ = false;
                    return;
                }
                Context context = view.getContext();
                if (doo.ˊ(context)) {
                    int i2 = i == 0 ? 1 : 2;
                    Intent intent = new Intent("com.huawei.appmarket.service.broadcast.ReplyFilter");
                    intent.putExtra("com.huawei.appmarket.service.broadcast.ReplyFilter", i2);
                    ll.ˏ(context).ˋ(intent);
                    return;
                }
                evk.ˋ(context, context.getResources().getString(h.ᐝʽ), 0).ˋ();
            }

            public void onNothingSelected(AdapterView<?> adapterView) {
            }
        });
    }

    public boolean ˋ(List<JsonBean> list) {
        this.ˋॱ = (ReplyComment) list.get(0);
        ॱॱ();
        if (this.ˋॱ != null) {
            ͺ();
            ˋ(this.ˋॱ.ॱ(), this.ˋॱ.ˎ());
            ॱˊ();
            this.ʿ.setText(this.ॱॱ.ˋ().getResources().getQuantityString(f.ˎ, this.ˊ.ॱ(), new Object[]{Integer.valueOf(this.ˊ.ॱ())}));
            if (this.ˊ.ˏ() != null) {
                this.ᐝ.setCommentInfo(this.ˊ.ˏ());
                if (TextUtils.isEmpty(this.ॱˊ)) {
                    this.ॱˊ = this.ˊ.ˏ().ˎ();
                }
            }
        }
        return true;
    }

    private void ॱॱ() {
        if (this.ˊ.ॱ() == 0) {
            this.ॱᐝ.setVisibility(8);
            this.ʽॱ.setVisibility(8);
            return;
        }
        this.ॱᐝ.setVisibility(0);
        this.ʽॱ.setVisibility(0);
    }

    public void ˏ(boolean z, BaseRequest o_cvu, ResponseBean responseBean) {
        this.ॱˋ = true;
        ॱॱ();
        if (!z) {
            this.ˏ.ॱˊ();
        }
        GetReplyResBean getReplyResBean = (GetReplyResBean) responseBean;
        if (responseBean.getResponseCode() == 3) {
            if (this.ॱॱ.isShown()) {
                this.ॱॱ.setVisibility(8);
            }
            ckv.ˎ(this.ॱॱ.getContext().getString(h.ᐝʽ), 0);
            return;
        }
        this.ˏ.setSelectionFromTop(this.ˈ, this.ˋˊ);
        if (this.ʻॱ) {
            ͺ();
            if (TextUtils.isEmpty(this.ॱˊ) && getReplyResBean.ˏ() != null) {
                this.ॱˊ = getReplyResBean.ˏ().ˎ();
            }
            if (!(TextUtils.isEmpty(this.ॱˊ) || this.ॱॱ.isShown())) {
                ˋ(null, this.ॱˊ);
                ॱˊ();
            }
            if (this.ᐝ.ˏ() == null) {
                this.ᐝ.setCommentInfo(getReplyResBean.ˏ());
            }
        }
        this.ʿ.setText(this.ॱॱ.ˋ().getResources().getQuantityString(f.ˎ, getReplyResBean.ˊ(), new Object[]{Integer.valueOf(getReplyResBean.ˊ())}));
    }

    private void ᐝ() {
        if (this.ॱॱ != null && (this.ॱॱ.getContext() instanceof Activity)) {
            ((Activity) this.ॱॱ.getContext()).getWindow().setSoftInputMode(21);
        }
    }

    private void ˏॱ() {
        if (this.ॱॱ != null && (this.ॱॱ.getContext() instanceof Activity)) {
            ((Activity) this.ॱॱ.getContext()).getWindow().setSoftInputMode(3);
        }
    }

    private void ͺ() {
        int i = 8;
        AppCommentInfo ˏ = this.ˊ.ˏ();
        if (ˏ == null) {
            this.ॱॱ.setVisibility(8);
            ˋ(8);
            return;
        }
        String string;
        ˋ(0);
        this.ˏ.setVisibility(0);
        if (!TextUtils.isEmpty(ˏ.ˊˊ())) {
            eqx.ˏ(this.ˊˋ, ˏ.ˊˊ(), "app_default_icon");
        }
        if (TextUtils.isEmpty(ˏ.ˊॱ())) {
            this.ˊᐝ.setVisibility(8);
        } else {
            this.ˊᐝ.setVisibility(0);
            this.ˊᐝ.setText(ˏ.ˊॱ() + ContentManager.getInstant().getContext().getResources().getString(h.ᴵ));
        }
        ˎ(this.ˊˊ, ˏ.ˊˋ());
        ˎ((TextView) this.ˉ.findViewById(e.ʼʼ), ˏ.ˋᐝ());
        ˋ(ˏ);
        TextView textView = (TextView) this.ᐝ.findViewById(e.ॱﹳ);
        textView.setText(ˏ.ˎ());
        View view = this.ᐝ.ˋ;
        if (ˏ.ॱॱ() == 6) {
            i = 0;
        }
        view.setVisibility(i);
        ˊ(ˏ);
        ˎ((TextView) this.ᐝ.findViewById(e.ॱᐨ), ˏ.ˋ());
        TextView textView2 = (TextView) this.ᐝ.findViewById(e.ॱـ);
        if (ˏ.ʻॱ() == 1) {
            ˎ(textView2, bei.ॱ(this.ᐝ.getContext(), ˏ.ʻ()) + "(" + this.ᐝ.getContext().getString(h.ˎˎ) + ")");
        } else {
            ˎ(textView2, bei.ॱ(this.ᐝ.getContext(), ˏ.ʻ()));
        }
        textView2 = (TextView) this.ᐝ.findViewById(e.ˋʻ);
        ˎ(textView2, ˏ.ͺ());
        textView2.setTextIsSelectable(true);
        RatingBar ratingBar = (RatingBar) this.ᐝ.findViewById(e.ॱˉ);
        float f = 0.0f;
        try {
            f = Float.parseFloat(ˏ.ʼ());
        } catch (NumberFormatException e) {
            bcb.ˋ.ˏ(ˎ, "rating value  rating:" + ˏ.ʼ() + "error=" + e.toString());
        }
        ratingBar.setRating(f);
        textView2 = (TextView) this.ᐝ.findViewById(e.ॱꜟ);
        if (!TextUtils.isEmpty(ˏ.ˈ()) && ˏ.ˈ().equals(ˏ.ॱᐝ())) {
            string = textView.getContext().getString(h.ʽॱ);
        } else if (TextUtils.isEmpty(ˏ.ॱᐝ())) {
            string = null;
        } else {
            string = String.format(Locale.ENGLISH, textView.getContext().getString(h.ॱﹳ), new Object[]{ˏ.ॱᐝ()});
        }
        ˎ(textView2, string);
        ॱ(ˏ);
    }

    private void ˋ(AppCommentInfo appCommentInfo) {
        ImageView imageView = (ImageView) this.ᐝ.findViewById(e.ॱㆍ);
        if (TextUtils.isEmpty(appCommentInfo.ˏ())) {
            imageView.setImageResource(bcg.c.ᐝॱ);
        } else {
            cea.ˏ(imageView, appCommentInfo.ˏ(), "head_default_icon");
        }
        imageView.setOnClickListener(new ckt(new bek.e(appCommentInfo.ˊ())));
    }

    private void ˊ(AppCommentInfo appCommentInfo) {
        String string;
        if (1 == appCommentInfo.ʾ()) {
            string = this.ᐝ.getResources().getString(h.ﾟ);
        } else if (2 == appCommentInfo.ʾ()) {
            string = this.ᐝ.getResources().getString(h.ᐝˋ);
        } else {
            string = "";
        }
        ˎ((TextView) this.ᐝ.findViewById(e.ॱᐧ), string);
    }

    private void ॱ(AppCommentInfo appCommentInfo) {
        HwTextView hwTextView = (HwTextView) this.ᐝ.findViewById(e.ʿॱ);
        HwTextView hwTextView2 = (HwTextView) this.ᐝ.findViewById(e.ॱˈ);
        AppCommentInfo appCommentInfo2 = appCommentInfo;
        ˏ(appCommentInfo2, (ImageView) this.ᐝ.findViewById(e.ˊʻ), hwTextView, (ImageView) this.ᐝ.findViewById(e.ˏͺ), (HwTextView) this.ᐝ.findViewById(e.ˎͺ));
        ˏ(hwTextView);
        ˏ(hwTextView2);
    }

    private void ˏ(AppCommentInfo appCommentInfo, ImageView imageView, TextView textView, ImageView imageView2, TextView textView2) {
        if (appCommentInfo.ˋॱ() == 1) {
            imageView.setBackgroundResource(bcg.c.ˎ);
        } else {
            imageView.setBackgroundResource(bcg.c.ˏ);
        }
        if (appCommentInfo.ॱˊ() != 0) {
            ˎ(textView, cgy.ˎ((double) appCommentInfo.ॱˊ()));
            imageView.setContentDescription(textView.getContext().getString(h.ㆍ));
        } else {
            imageView.setContentDescription(null);
            textView.setText(textView.getContext().getString(h.ㆍ));
        }
        if (appCommentInfo.ˏॱ() == 1) {
            imageView2.setBackgroundResource(bcg.c.ͺ);
        } else {
            imageView2.setBackgroundResource(bcg.c.ʼ);
        }
        if (appCommentInfo.ॱˋ() != 0) {
            ˎ(textView2, cgy.ˎ((double) appCommentInfo.ॱˋ()));
            imageView2.setContentDescription(imageView2.getContext().getString(h.ᐝˊ));
            return;
        }
        imageView2.setContentDescription(null);
        textView2.setText(textView2.getContext().getString(h.ᐝˊ));
    }

    private void ˏ(HwTextView hwTextView) {
        if (!ber.ˊ(hwTextView.getContext())) {
            hwTextView.setMaxWidth(cdo.ˏ(hwTextView.getContext(), 42));
        }
        hwTextView.setAutoTextInfo(hwTextView.getContext().getResources().getDimensionPixelSize(o.bcg.b.ˎ), hwTextView.getContext().getResources().getDimensionPixelSize(o.bcg.b.ˋ), 0);
    }

    public void ˏ() {
        this.ˏ.ʻ();
    }

    private void ˎ(TextView textView, String str) {
        if (TextUtils.isEmpty(str)) {
            textView.setVisibility(8);
            return;
        }
        textView.setVisibility(0);
        textView.setText(str);
    }

    public void ˋ() {
        this.ˊ = null;
    }

    public void onClick(View view) {
        this.ʻ = (long) view.getId();
        if (view.getId() == e.ˋᐝ) {
            ˋ(view);
        } else {
            new bdr((Activity) view.getContext(), new bdz(this) {
                final /* synthetic */ bea ˏ;

                {
                    this.ˏ = r1;
                }

                public void ˊ() {
                    this.ˏ.ˊ.ˏ(2);
                    this.ˏ.ˏ(this.ˏ.ʻ);
                    this.ˏ.ॱˊ();
                }

                public void ˋ() {
                }
            }).ˎ();
        }
    }

    private void ˋ(String str, String str2) {
        this.ॱॱ.setCommentId(this.ʼ);
        if (this.ˋॱ != null) {
            this.ˋॱ.ˏ(str);
            this.ˋॱ.ˎ(str2);
        }
        if (TextUtils.isEmpty(str)) {
            this.ॱॱ.setReplyID("");
        } else {
            this.ॱॱ.setReplyID(str);
        }
        if (!TextUtils.isEmpty(str2)) {
            this.ॱॱ.setContentHint(String.format(this.ॱॱ.getContext().getString(h.ٴ), new Object[]{str2}));
            this.ॱॱ.setUserName(str2);
        }
    }

    private void ॱˊ() {
        if (this.ˊ.ˏ() == null) {
            this.ॱॱ.setVisibility(8);
        } else if (this.ʻॱ) {
            this.ʻॱ = false;
            if (this.ॱˋ) {
                this.ॱॱ.setVisibility(0);
                this.ˊ.ˏ(1);
                if (this.ˊ.ॱ() == 0) {
                    ᐝ();
                    this.ʽ.setFocusableInTouchMode(true);
                    this.ʽ.requestFocus();
                    this.ˊ.ˏ(2);
                }
            } else if (1 == this.ˊ.ˎ()) {
                this.ॱॱ.setVisibility(0);
            } else if (2 == this.ˊ.ˎ()) {
                this.ॱॱ.setVisibility(0);
                ᐝ();
                this.ʽ.setFocusableInTouchMode(true);
                this.ʽ.requestFocus();
            }
        } else if (2 == this.ˊ.ˎ() && this.ॱˎ.ॱˋ() != null) {
            this.ॱॱ.setVisibility(0);
            View currentFocus = this.ॱˎ.ॱˋ().getCurrentFocus();
            if (currentFocus != null) {
                currentFocus.clearFocus();
            }
            ᐝ();
            this.ʽ.setFocusableInTouchMode(true);
            this.ʽ.requestFocus();
            this.ˊ.ˏ(2);
        }
    }

    private void ˏ(long j) {
        if (this.ˊ != null) {
            ReplyComment ˊ = this.ˊ.ˊ(Long.valueOf(j).intValue());
            if (ˊ != null) {
                String str = "";
                ˋ(ˊ.ॱ(), ˊ.ˎ());
            }
        }
    }

    public void onScrollStateChanged(AbsListView absListView, int i) {
        if (i == 0) {
            ॱ();
            this.ˈ = this.ˏ.getFirstVisiblePosition();
        }
        if (1 == i) {
            this.ˎˎ = ˊॱ();
        }
        if (this.ˊ.ॱ() != 0) {
            View childAt = this.ˏ.getChildAt(0);
            this.ˋˊ = childAt == null ? 0 : childAt.getTop();
        }
        if (absListView.getFirstVisiblePosition() == 0 && this.ˋᐝ > 0) {
            childAt = absListView.getChildAt(0);
            if (childAt != null && childAt.getTop() == 0) {
                ॱˎ();
            }
        }
    }

    public void onScroll(AbsListView absListView, int i, int i2, int i3) {
        int ˊॱ = ˊॱ();
        ˎ(absListView, i);
        if (!this.ͺॱ) {
            return;
        }
        if (ˊॱ - this.ˎˎ < (-this.ˋᐝ) && this.ˏˏ == -1) {
            ॱˎ();
        } else if (ˊॱ - this.ˎˎ > this.ˋᐝ && this.ˏˏ == 1) {
            ˋॱ();
        }
    }

    private void ˎ(AbsListView absListView, int i) {
        this.ॱ = i;
        View childAt = absListView.getChildAt(0);
        if (childAt != null) {
            b bVar = (b) this.ˋ.get(i);
            if (bVar == null) {
                bVar = new b();
            }
            bVar.ˊ = childAt.getHeight();
            bVar.ॱ = childAt.getTop();
            this.ˋ.append(i, bVar);
        }
        int top = childAt == null ? 0 : childAt.getTop();
        this.ˏˏ = 0;
        if (i > this.ˌ) {
            this.ˏˏ = 1;
        } else if (i < this.ˌ) {
            this.ˏˏ = -1;
        } else if (top < this.ˍ) {
            this.ˏˏ = 1;
        } else if (top > this.ˍ) {
            this.ˏˏ = -1;
        }
        this.ˌ = i;
        this.ˍ = top;
    }

    private int ˊॱ() {
        b bVar;
        int i = 0;
        for (int i2 = 0; i2 < this.ॱ; i2++) {
            bVar = (b) this.ˋ.get(i2);
            if (bVar != null) {
                i += bVar.ˊ;
            }
        }
        bVar = (b) this.ˋ.get(this.ॱ);
        if (bVar == null) {
            bVar = new b();
        }
        return i - bVar.ॱ;
    }

    public void ॱ(String str) {
        this.ʼ = str;
    }

    public void ˎ(String str) {
        this.ॱˊ = str;
    }

    public void ˏ(String str) {
        this.ˊॱ = str;
    }

    public void ˋ(boolean z) {
        this.ͺॱ = z;
    }

    public void ॱ() {
        InputMethodManager inputMethodManager = (InputMethodManager) this.ॱॱ.getContext().getSystemService("input_method");
        if (inputMethodManager.isActive()) {
            inputMethodManager.hideSoftInputFromWindow(this.ʽ.getWindowToken(), 2);
        }
        if (this.ˊ != null) {
            this.ˊ.ˏ(0);
        }
        this.ॱॱ.setVisibility(8);
    }

    public void ˊ(String str) {
        Intent intent = new Intent("com.huawei.appmarket.service.broadcast.CommentReplyAdded");
        intent.putExtra("ACTION_PARAM_COMMENT_REPLY_ADDED_TYPE_COMMENTID", str);
        intent.putExtra("ACTION_PARAM_COMMENT_ADDED_TYPE_APPID", this.ˊॱ);
        ll.ˏ(this.ॱॱ.getContext()).ˋ(intent);
    }

    public boolean ˎ() {
        boolean z = this.ॱॱ.getVisibility() == 0;
        if (z) {
            ॱ();
        }
        return z;
    }

    public void ˋ(bdm.e eVar) {
        this.ᐝ.ॱ(eVar);
    }

    public void ʽ() {
        this.ˋˋ.notifyDataSetChanged();
    }

    public void ˎ(bdm.e eVar) {
        this.ᐝ.ˎ(eVar);
    }

    public void ˊ() {
        if ((this.ॱॱ.getVisibility() == 8 ? 1 : null) != null) {
            ˏॱ();
        }
    }

    public void ˏ(int i) {
        this.ˏॱ = i;
    }

    private void ˋॱ() {
        if (this.ˉ.getVisibility() == 0) {
            Animation translateAnimation = new TranslateAnimation(0.0f, 0.0f, 0.0f, (float) (0 - this.ˋᐝ));
            translateAnimation.setDuration(500);
            translateAnimation.setFillEnabled(true);
            translateAnimation.setFillAfter(true);
            translateAnimation.setAnimationListener(new AnimationListener(this) {
                final /* synthetic */ bea ˏ;

                {
                    this.ˏ = r1;
                }

                public void onAnimationStart(Animation animation) {
                }

                public void onAnimationEnd(Animation animation) {
                    this.ˏ.ˉ.clearAnimation();
                }

                public void onAnimationRepeat(Animation animation) {
                }
            });
            this.ˉ.setAnimation(translateAnimation);
            this.ˉ.setVisibility(8);
        }
    }

    private void ॱˎ() {
        if (this.ˉ.getVisibility() == 8) {
            Animation translateAnimation = new TranslateAnimation(0.0f, 0.0f, (float) (0 - this.ˋᐝ), 0.0f);
            translateAnimation.setDuration(500);
            translateAnimation.setFillEnabled(true);
            translateAnimation.setFillAfter(true);
            translateAnimation.setAnimationListener(new AnimationListener(this) {
                final /* synthetic */ bea ˎ;

                {
                    this.ˎ = r1;
                }

                public void onAnimationStart(Animation animation) {
                }

                public void onAnimationEnd(Animation animation) {
                    this.ˎ.ˉ.clearAnimation();
                }

                public void onAnimationRepeat(Animation animation) {
                }
            });
            this.ˉ.setAnimation(translateAnimation);
            this.ˉ.setVisibility(0);
        }
    }

    private void ˋ(@NonNull View view) {
        AppCommentInfo ˏ = this.ˊ.ˏ();
        if (ˏ == null) {
            bcb.ˋ.ˋ(ˎ, "appCommentInfo is null");
            return;
        }
        String ˋˊ = ˏ.ˋˊ();
        cjo appDetailActivityProtocol = new AppDetailActivityProtocol();
        Request request = new Request("app|" + ˋˊ, null);
        request.ˋ(0);
        appDetailActivityProtocol.ˏ(request);
        cjk.ˎ().ˋ(view.getContext(), new cjm("appdetail.activity", appDetailActivityProtocol));
    }
}
